<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.16"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>LibTools: CSafeSList&lt; T &gt; 模板类 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">LibTools
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.8.16 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',false,false,'search.php','搜索');
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public 成员函数</a> &#124;
<a href="#pri-attribs">Private 属性</a> &#124;
<a href="class_c_safe_s_list-members.html">所有成员列表</a>  </div>
  <div class="headertitle">
<div class="title">CSafeSList&lt; T &gt; 模板类 参考</div>  </div>
</div><!--header-->
<div class="contents">

<p>线程安全操作链表类  
 <a href="class_c_safe_s_list.html#details">更多...</a></p>

<p><code>#include &lt;<a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public 成员函数</h2></td></tr>
<tr class="memitem:ab6d59be07d96023caf676116c6ace138"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#ab6d59be07d96023caf676116c6ace138">Empty</a> ()</td></tr>
<tr class="memdesc:ab6d59be07d96023caf676116c6ace138"><td class="mdescLeft">&#160;</td><td class="mdescRight">判断链表中是否为空  <a href="class_c_safe_s_list.html#ab6d59be07d96023caf676116c6ace138">更多...</a><br /></td></tr>
<tr class="separator:ab6d59be07d96023caf676116c6ace138"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:affd47329140b999b7bd07fbb8d7167d1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#affd47329140b999b7bd07fbb8d7167d1">InsertBack</a> (const T &amp;value)</td></tr>
<tr class="memdesc:affd47329140b999b7bd07fbb8d7167d1"><td class="mdescLeft">&#160;</td><td class="mdescRight">向链表尾部中插入一个数据  <a href="class_c_safe_s_list.html#affd47329140b999b7bd07fbb8d7167d1">更多...</a><br /></td></tr>
<tr class="separator:affd47329140b999b7bd07fbb8d7167d1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6bec05153ef6502e832e561db26ad5eb"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#a6bec05153ef6502e832e561db26ad5eb">PopFront</a> (T &amp;value)</td></tr>
<tr class="memdesc:a6bec05153ef6502e832e561db26ad5eb"><td class="mdescLeft">&#160;</td><td class="mdescRight">删除链表头部数据，并返回相应的值  <a href="class_c_safe_s_list.html#a6bec05153ef6502e832e561db26ad5eb">更多...</a><br /></td></tr>
<tr class="separator:a6bec05153ef6502e832e561db26ad5eb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3c301d884f8f9f5b92b78711ad945613"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#a3c301d884f8f9f5b92b78711ad945613">Front</a> (T &amp;value)</td></tr>
<tr class="memdesc:a3c301d884f8f9f5b92b78711ad945613"><td class="mdescLeft">&#160;</td><td class="mdescRight">返回链表的头部数据，并删除  <a href="class_c_safe_s_list.html#a3c301d884f8f9f5b92b78711ad945613">更多...</a><br /></td></tr>
<tr class="separator:a3c301d884f8f9f5b92b78711ad945613"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5248872778d230ffb571d16b901c0149"><td class="memItemLeft" align="right" valign="top"><a class="el" href="tools_8h.html#a36cb3b01d81ffd844bbbfb54003e06ec">UINT</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#a5248872778d230ffb571d16b901c0149">Size</a> ()</td></tr>
<tr class="memdesc:a5248872778d230ffb571d16b901c0149"><td class="mdescLeft">&#160;</td><td class="mdescRight">返回链表的大小  <a href="class_c_safe_s_list.html#a5248872778d230ffb571d16b901c0149">更多...</a><br /></td></tr>
<tr class="separator:a5248872778d230ffb571d16b901c0149"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private 属性</h2></td></tr>
<tr class="memitem:ab22ac904b04b864f9a34001b79b44a80"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_c_mutex.html">CMutex</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#ab22ac904b04b864f9a34001b79b44a80">_mutexList</a></td></tr>
<tr class="separator:ab22ac904b04b864f9a34001b79b44a80"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab9e942724c0cce2b04831249fa1b295b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_s_list.html">SList</a>&lt; T &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_c_safe_s_list.html#ab9e942724c0cce2b04831249fa1b295b">_list</a></td></tr>
<tr class="separator:ab9e942724c0cce2b04831249fa1b295b"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock"><h3>template&lt;class T&gt;<br />
class CSafeSList&lt; T &gt;</h3>

<p>线程安全操作链表类 </p>

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00012">12</a> 行定义.</p>
</div><h2 class="groupheader">成员函数说明</h2>
<a id="ab6d59be07d96023caf676116c6ace138"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab6d59be07d96023caf676116c6ace138">&#9670;&nbsp;</a></span>Empty()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::Empty </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>判断链表中是否为空 </p>
<dl class="section return"><dt>返回</dt><dd>为空返回true,否则返回false </dd></dl>
<dl class="section remark"><dt>备注</dt><dd>使用时应当小心，多线程的情况下不能保证其值的正确性 </dd></dl>

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00020">20</a> 行定义.</p>

</div>
</div>
<a id="a3c301d884f8f9f5b92b78711ad945613"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3c301d884f8f9f5b92b78711ad945613">&#9670;&nbsp;</a></span>Front()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::Front </td>
          <td>(</td>
          <td class="paramtype">T &amp;&#160;</td>
          <td class="paramname"><em>value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>返回链表的头部数据，并删除 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">value</td><td>接收链表返回的数据值 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>如果有数据则返回true,否则返回false </dd></dl>

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00054">54</a> 行定义.</p>

</div>
</div>
<a id="affd47329140b999b7bd07fbb8d7167d1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#affd47329140b999b7bd07fbb8d7167d1">&#9670;&nbsp;</a></span>InsertBack()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::InsertBack </td>
          <td>(</td>
          <td class="paramtype">const T &amp;&#160;</td>
          <td class="paramname"><em>value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>向链表尾部中插入一个数据 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">value</td><td>需要插入的值 </td></tr>
  </table>
  </dd>
</dl>

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00030">30</a> 行定义.</p>

</div>
</div>
<a id="a6bec05153ef6502e832e561db26ad5eb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6bec05153ef6502e832e561db26ad5eb">&#9670;&nbsp;</a></span>PopFront()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::PopFront </td>
          <td>(</td>
          <td class="paramtype">T &amp;&#160;</td>
          <td class="paramname"><em>value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>删除链表头部数据，并返回相应的值 </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramname">value</td><td>接收返回头部的值 </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>返回</dt><dd>成功返回true，失败返回false </dd></dl>

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00041">41</a> 行定义.</p>

</div>
</div>
<a id="a5248872778d230ffb571d16b901c0149"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a5248872778d230ffb571d16b901c0149">&#9670;&nbsp;</a></span>Size()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="tools_8h.html#a36cb3b01d81ffd844bbbfb54003e06ec">UINT</a> <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::Size </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>返回链表的大小 </p>
<dl class="section remark"><dt>备注</dt><dd>使用时应当小心，多线程的情况下不能保证其值的实时性 </dd></dl>

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00066">66</a> 行定义.</p>

</div>
</div>
<h2 class="groupheader">类成员变量说明</h2>
<a id="ab9e942724c0cce2b04831249fa1b295b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab9e942724c0cce2b04831249fa1b295b">&#9670;&nbsp;</a></span>_list</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_s_list.html">SList</a>&lt;T&gt; <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::_list</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00072">72</a> 行定义.</p>

</div>
</div>
<a id="ab22ac904b04b864f9a34001b79b44a80"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab22ac904b04b864f9a34001b79b44a80">&#9670;&nbsp;</a></span>_mutexList</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_c_mutex.html">CMutex</a> <a class="el" href="class_c_safe_s_list.html">CSafeSList</a>&lt; T &gt;::_mutexList</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p class="definition">在文件 <a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a> 第 <a class="el" href="_c_safe_s_list_8h_source.html#l00071">71</a> 行定义.</p>

</div>
</div>
<hr/>该类的文档由以下文件生成:<ul>
<li>H:/project/LibTools/src/algorithm/<a class="el" href="_c_safe_s_list_8h_source.html">CSafeSList.h</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
制作者 &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.16
</small></address>
</body>
</html>
